﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace WindowsFormsApplication1.DTO
{
    class ChamCongDTO
    {
        public string maGiaoVien;
        public string hoTen, donVi;
        public int deDaRa, baiDaCham, toChuc;
        public float congRaDe, congChamBai, congToChuc, congCoiThi, congInDe, tongTiet;

        public ChamCongDTO(string maGiaoVien, string hoTen)
        {
            this.maGiaoVien = maGiaoVien;
            this.hoTen = hoTen;
        }

        public string[] ToStrings()
        {
            string[] a = new string[12];

            a[0] = maGiaoVien == null ? "" : maGiaoVien;
            a[1] = hoTen == null ? "" : hoTen;
            a[2] = donVi == null ? "" : donVi;
            a[3] = deDaRa.ToString();
            a[4] = baiDaCham.ToString();
            a[5] = toChuc.ToString();
            a[6] = congRaDe.ToString();
            a[7] = congChamBai.ToString();
            a[8] = congToChuc.ToString();
            a[9] = congCoiThi.ToString();
            a[10] = congInDe.ToString();
            a[11] = tongTiet.ToString();

            return a;
        }

        public ChamCongDTO Clone(ChamCongDTO src)
        {
            ChamCongDTO cc = new ChamCongDTO(src.maGiaoVien,src.hoTen);
            return cc;
        }
    }
}
